<script type="text/javascript" src="<{$config.weburl}>/script/jquery.flexslider-min.js"></script>
<link href="<{$config.weburl}>/module/product/templates/pro.css" rel="stylesheet" type="text/css" />
<div class="w clearfix">
	<div class="adv">
		<script src='<{$config.weburl}>/api/ad.php?id=2'></script>
	</div>
    <div class="right_side">
        <div class="service">
            <h3>特色服务</h3>
            <ul>
                <li>
                    <a target="_blank" href="main.php"><img src="image/default/service_1.jpg"></a>
                    <span><a target="_blank" href="main.php">个人中心</a></span>
                </li>
                <li>
                    <a target="_blank" href="?m=points"><img src="image/default/service_2.jpg"></a>
                    <span><a target="_blank" href="?m=points">积分商城</a></span>
                </li>
                <li>
                    <a target="_blank" href="?m=product&s=list"><img src="image/default/service_3.jpg"></a>
                    <span><a target="_blank" href="?m=product&s=list">热销榜</a></span>
                </li>
            </ul>
        </div>
        <div class="notice">
			<ul class="tit"><li><a href="javascript:void(0)">公告栏</a></li></ul>
            <div class="con">
                <ul><{insert name="getNotice" limit=5}></ul>
            </div>
        </div>
        <div class="ad198x172"><script src='<{$config.weburl}>/api/ad.php?id=3'></script></div>
	</div>
</div>
<div class="w clearfix">
    <div class="hot">
        <{foreach item=val key=num from=$type}>
        <div class="fore<{$num+1}> <{if $num==0}>current<{/if}>">
            <div class="mt">
            <h2><{$val.name}></h2>
            <div class="tab-arrow"><b></b></div>
            </div>    
            <div class="mc">
                <ul><{insert name="label" type="product" product_id=$val.id temp="product_list_li" limit=5}></ul>
            </div>
        </div>
        <{/foreach}>
        <script type="text/javascript">
        $(".hot .mt").bind("mouseover",function(){
            var element=$(this).parent();
            element.addClass("current").siblings().removeClass("current");
        });
        </script>
    </div>
    <div class="tg">
        <div class="mt">
            <h2>今日团购</h2>
        </div>
        <div class="mc clearfix">
        <{if 0}>
            <{insert name="label" type="tg" rec=2 temp="tg_list_2" limit=1}><{/if}>
        </div>
    </div>
</div>
<{foreach item=slist key=key from=$categorys}>
    <div class="w w1 clearfix"> 
    	<div class="catalogue">
        	<div class="mt ld">
            	<div class="floor">
                	<b class="b b1"></b>
                    <b class="b b2"></b>
                    <b class="b b3"><{$key+1}>F</b>
                    <b class="b4"></b>
                </div>
            	<h2><{$slist.name}></h2>
            </div>
            <div class="mc">
            	<ul>
                	<{foreach item=cat key=num from=$slist.sub_cat}>
                		<li><a href="?m=product&s=list&id=<{$cat.catid}>"><{$cat.cat}></a></li>
                    <{/foreach}>
                </ul>
                <span>
                 <script src='<{$config.weburl}>/api/ad.php?id=6&catid=<{$key+1}>'></script>
                </span>
            </div>
        </div>
        <div class="plist">
        	<div class="tab-arrow"><b></b></div>
            <div class="fore1 curr">
            	<div class="smt"><h3>特价商品</h3></div>
                <div class="smc">
                    <script src='<{$config.weburl}>/api/ad.php?id=7&catid=<{$key+1}>'></script>
					<ul class="ul"><{insert name="label" catid=$slist.catid type="product" temp="product_list_li" limit=7}></ul>
                </div>
            </div>
            <{foreach item=cat key=num from=$slist.sub_cat}>
            <{if $num<4}>
            <div class="fore<{$num+2}>">
            	<div class="smt"><h3><{$cat.cat}></h3></div>
                <div class="smc">
					<ul class="ul"><{insert name="label" catid=$cat.catid type="product" temp="product_list_li" limit=10}></ul>
                </div>
            </div>
            <{/if}>
            <{/foreach}>
        </div>
        <div class="brands">
        	<div class="smt"><h3>品牌首席馆</h3></div>
        	<div class="smc">
                <ul>
                <{foreach item=rlist from=$slist.brand}>
                    <li>
                    <a target="_blank" href="<{$config.weburl}>/?m=product&s=list&brand=<{$rlist.name}>"><img width="98" height="44" align="<{$rlist.name}>" src="<{$rlist.logo}>"/></a>
                    </li>
                <{/foreach}>
                </ul>
            </div>
        </div>
        <div class="ad219x179"><script src='<{$config.weburl}>/api/ad.php?id=8&catid=<{$key+1}>'></script></div>
    </div>
<{/foreach}>
<script type="text/javascript">
$(".plist .smt").bind("mouseover",function(){
	var element=$(this).parent();
	var index = $(this).parent().index()-1;
	element.addClass("curr").siblings().removeClass("curr");
	element.parent().find(".tab-arrow").css('left',index*158+'px')
	
});
</script>


